home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1999 July: Mac OS SDK / Dev.CD Jul 99 SDK1.toast / Development Kits / Mac OS / Interfaces&Libraries / Universal / Interfaces / CIncludes / FSM.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-08-17  |  34.0 KB  |  967 lines  |  [TEXT/MPS ]

  1. /*
  2.      File:        FSM.h
  3.  
  4.      Contains:    HFS External File System Interfaces.
  5.  
  6.      Version:    Technology:    System 7.5
  7.                  Release:    Universal Interfaces 3.2
  8.  
  9.      Copyright:    © 1985-1998 by Apple Computer, Inc., all rights reserved
  10.  
  11.      Bugs?:        For bug reports, consult the following page on
  12.                  the World Wide Web:
  13.  
  14.                      http://developer.apple.com/bugreporter/
  15.  
  16. */
  17. #ifndef __FSM__
  18. #define __FSM__
  19.  
  20. #ifndef __FILES__
  21. #include <Files.h>
  22. #endif
  23.  
  24.  
  25.  
  26. #if PRAGMA_ONCE
  27. #pragma once
  28. #endif
  29.  
  30. #ifdef __cplusplus
  31. extern "C" {
  32. #endif
  33.  
  34. #if PRAGMA_IMPORT
  35. #pragma import on
  36. #endif
  37.  
  38. #if PRAGMA_STRUCT_ALIGN
  39.     #pragma options align=mac68k
  40. #elif PRAGMA_STRUCT_PACKPUSH
  41.     #pragma pack(push, 2)
  42. #elif PRAGMA_STRUCT_PACK
  43.     #pragma pack(2)
  44. #endif
  45.  
  46. /* VolMount declarations are now in Files.≈ */
  47.  
  48. /*
  49.  * Miscellaneous file system values not in Files.≈
  50.  */
  51.  
  52. enum {
  53.     fsUsrCNID                    = 16,                            /* First assignable directory or file number */
  54.                                                                 /*    File system trap word attribute bits */
  55.     kHFSBit                        = 9,                            /* HFS call: bit 9 */
  56.     kHFSMask                    = 0x0200,
  57.     kAsyncBit                    = 10,                            /* Asynchronous call: bit 10 */
  58.     kAsyncMask                    = 0x0400
  59. };
  60.  
  61.  
  62. /*
  63.  * HFSCIProc selectCode values
  64.  * Note: The trap attribute bits (the HFS bit and the asynchronous bit)
  65.  * may be set in these selectCode values.
  66.  */
  67.  
  68. enum {
  69.     kFSMOpen                    = 0xA000,
  70.     kFSMClose                    = 0xA001,
  71.     kFSMRead                    = 0xA002,
  72.     kFSMWrite                    = 0xA003,
  73.     kFSMGetVolInfo                = 0xA007,
  74.     kFSMCreate                    = 0xA008,
  75.     kFSMDelete                    = 0xA009,
  76.     kFSMOpenRF                    = 0xA00A,
  77.     kFSMRename                    = 0xA00B,
  78.     kFSMGetFileInfo                = 0xA00C,
  79.     kFSMSetFileInfo                = 0xA00D,
  80.     kFSMUnmountVol                = 0xA00E,
  81.     kFSMMountVol                = 0xA00F,
  82.     kFSMAllocate                = 0xA010,
  83.     kFSMGetEOF                    = 0xA011,
  84.     kFSMSetEOF                    = 0xA012,
  85.     kFSMFlushVol                = 0xA013,
  86.     kFSMGetVol                    = 0xA014,
  87.     kFSMSetVol                    = 0xA015,
  88.     kFSMEject                    = 0xA017,
  89.     kFSMGetFPos                    = 0xA018,
  90.     kFSMOffline                    = 0xA035,
  91.     kFSMSetFilLock                = 0xA041,
  92.     kFSMRstFilLock                = 0xA042,
  93.     kFSMSetFilType                = 0xA043,
  94.     kFSMSetFPos                    = 0xA044,
  95.     kFSMFlushFile                = 0xA045,                        /*    The File System HFSDispatch selectCodes */
  96.     kFSMOpenWD                    = 0x0001,
  97.     kFSMCloseWD                    = 0x0002,
  98.     kFSMCatMove                    = 0x0005,
  99.     kFSMDirCreate                = 0x0006,
  100.     kFSMGetWDInfo                = 0x0007,
  101.     kFSMGetFCBInfo                = 0x0008,
  102.     kFSMGetCatInfo                = 0x0009,
  103.     kFSMSetCatInfo                = 0x000A,
  104.     kFSMSetVolInfo                = 0x000B,
  105.     kFSMLockRng                    = 0x0010,
  106.     kFSMUnlockRng                = 0x0011,
  107.     kFSMXGetVolInfo                = 0x0012,
  108.     kFSMCreateFileIDRef            = 0x0014,
  109.     kFSMDeleteFileIDRef            = 0x0015,
  110.     kFSMResolveFileIDRef        = 0x0016,
  111.     kFSMExchangeFiles            = 0x0017,
  112.     kFSMCatSearch                = 0x0018,
  113.     kFSMOpenDF                    = 0x001A,
  114.     kFSMMakeFSSpec                = 0x001B,                        /*    The Desktop Manager HFSDispatch selectCodes */
  115.     kFSMDTGetPath                = 0x0020,
  116.     kFSMDTCloseDown                = 0x0021,
  117.     kFSMDTAddIcon                = 0x0022,
  118.     kFSMDTGetIcon                = 0x0023,
  119.     kFSMDTGetIconInfo            = 0x0024,
  120.     kFSMDTAddAPPL                = 0x0025,
  121.     kFSMDTRemoveAPPL            = 0x0026,
  122.     kFSMDTGetAPPL                = 0x0027,
  123.     kFSMDTSetComment            = 0x0028,
  124.     kFSMDTRemoveComment            = 0x0029,
  125.     kFSMDTGetComment            = 0x002A,
  126.     kFSMDTFlush                    = 0x002B,
  127.     kFSMDTReset                    = 0x002C,
  128.     kFSMDTGetInfo                = 0x002D,
  129.     kFSMDTOpenInform            = 0x002E,
  130.     kFSMDTDelete                = 0x002F,                        /*    The AppleShare HFSDispatch selectCodes */
  131.     kFSMGetVolParms                = 0x0030,
  132.     kFSMGetLogInInfo            = 0x0031,
  133.     kFSMGetDirAccess            = 0x0032,
  134.     kFSMSetDirAccess            = 0x0033,
  135.     kFSMMapID                    = 0x0034,
  136.     kFSMMapName                    = 0x0035,
  137.     kFSMCopyFile                = 0x0036,
  138.     kFSMMoveRename                = 0x0037,
  139.     kFSMOpenDeny                = 0x0038,
  140.     kFSMOpenRFDeny                = 0x0039,
  141.     kFSMGetXCatInfo                = 0x003A,
  142.     kFSMGetVolMountInfoSize        = 0x003F,
  143.     kFSMGetVolMountInfo            = 0x0040,
  144.     kFSMVolumeMount                = 0x0041,
  145.     kFSMShare                    = 0x0042,
  146.     kFSMUnShare                    = 0x0043,
  147.     kFSMGetUGEntry                = 0x0044,
  148.     kFSMGetForeignPrivs            = 0x0060,
  149.     kFSMSetForeignPrivs            = 0x0061
  150. };
  151.  
  152. /*
  153.  * UTDetermineVol status values
  154.  */
  155.  
  156. enum {
  157.     dtmvError                    = 0,                            /* param error */
  158.     dtmvFullPathame                = 1,                            /* determined by full pathname */
  159.     dtmvVRefNum                    = 2,                            /* determined by volume refNum */
  160.     dtmvWDRefNum                = 3,                            /* determined by working directory refNum */
  161.     dtmvDriveNum                = 4,                            /* determined by drive number */
  162.     dtmvDefault                    = 5                                /* determined by default volume */
  163. };
  164.  
  165.  
  166. /*
  167.  * UTGetBlock options
  168.  */
  169.  
  170. enum {
  171.     gbDefault                    = 0,                            /* default value - read if not found */
  172.                                                                 /*    bits and masks */
  173.     gbReadBit                    = 0,                            /* read block from disk (forced read) */
  174.     gbReadMask                    = 0x0001,
  175.     gbExistBit                    = 1,                            /* get existing cache block */
  176.     gbExistMask                    = 0x0002,
  177.     gbNoReadBit                    = 2,                            /* don't read block from disk if not found in cache */
  178.     gbNoReadMask                = 0x0004,
  179.     gbReleaseBit                = 3,                            /* release block immediately after GetBlock */
  180.     gbReleaseMask                = 0x0008
  181. };
  182.  
  183.  
  184. /*
  185.  * UTReleaseBlock options
  186.  */
  187.  
  188. enum {
  189.     rbDefault                    = 0,                            /* default value - just mark the buffer not in-use */
  190.                                                                 /*    bits and masks */
  191.     rbWriteBit                    = 0,                            /* force write buffer to disk */
  192.     rbWriteMask                    = 0x0001,
  193.     rbTrashBit                    = 1,                            /* trash buffer contents after release */
  194.     rbTrashMask                    = 0x0002,
  195.     rbDirtyBit                    = 2,                            /* mark buffer dirty */
  196.     rbDirtyMask                    = 0x0004,
  197.     rbFreeBit                    = 3,                            /* free the buffer (save in the hash) */
  198.     rbFreeMask                    = 0x000A                        /* rbFreeMask (rbFreeBit + rbTrashBit) works as rbTrash on < System 7.0 RamCache; on >= System 7.0, rbfreeMask overrides rbTrash */
  199. };
  200.  
  201.  
  202. /*
  203.  * UTFlushCache options
  204.  */
  205.  
  206. enum {
  207.     fcDefault                    = 0,                            /* default value - pass this fcOption to just flush any dirty buffers */
  208.                                                                 /*    bits and masks */
  209.     fcTrashBit                    = 0,                            /* (don't pass this as fcOption, use only for testing bit) */
  210.     fcTrashMask                    = 0x0001,                        /* pass this fcOption value to flush and trash cache blocks */
  211.     fcFreeBit                    = 1,                            /* (don't pass this as fcOption, use only for testing bit) */
  212.     fcFreeMask                    = 0x0003                        /* pass this fcOption to flush and free cache blocks (Note: both fcTrash and fcFree bits are set) */
  213. };
  214.  
  215.  
  216. /*
  217.  * UTCacheReadIP and UTCacheWriteIP cacheOption bits and masks are the ioPosMode
  218.  * bits and masks in Files.x
  219.  */
  220.  
  221. /*
  222.  * Cache routine internal error codes
  223.  */
  224.  
  225. enum {
  226.     chNoBuf                        = 1,                            /* no free cache buffers (all in use) */
  227.     chInUse                        = 2,                            /* requested block in use */
  228.     chnotfound                    = 3,                            /* requested block not found */
  229.     chNotInUse                    = 4                                /* block being released was not in use */
  230. };
  231.  
  232.  
  233. /*
  234.  * FCBRec.fcbFlags bits
  235.  */
  236.  
  237. enum {
  238.     fcbWriteBit                    = 0,                            /* Data can be written to this file */
  239.     fcbWriteMask                = 0x01,
  240.     fcbResourceBit                = 1,                            /* This file is a resource fork */
  241.     fcbResourceMask                = 0x02,
  242.     fcbWriteLockedBit            = 2,                            /* File has a locked byte range */
  243.     fcbWriteLockedMask            = 0x04,
  244.     fcbSharedWriteBit            = 4,                            /* File is open for shared write access */
  245.     fcbSharedWriteMask            = 0x10,
  246.     fcbFileLockedBit            = 5,                            /* File is locked (write-protected) */
  247.     fcbFileLockedMask            = 0x20,
  248.     fcbOwnClumpBit                = 6,                            /* File has clump size specified in FCB */
  249.     fcbOwnClumpMask                = 0x40,
  250.     fcbModifiedBit                = 7,                            /* File has changed since it was last flushed */
  251.     fcbModifiedMask                = 0x80
  252. };
  253.  
  254.  
  255. /*
  256.  *    HFS Component Interface constants
  257.  */
  258.  
  259. /*
  260.  * compInterfMask bits specific to HFS component
  261.  */
  262.  
  263. enum {
  264.     hfsCIDoesHFSBit                = 23,                            /* set if file system supports HFS calls */
  265.     hfsCIDoesHFSMask            = 0x00800000,
  266.     hfsCIDoesAppleShareBit        = 22,                            /* set if AppleShare calls supported */
  267.     hfsCIDoesAppleShareMask        = 0x00400000,
  268.     hfsCIDoesDeskTopBit            = 21,                            /* set if Desktop Database calls supported */
  269.     hfsCIDoesDeskTopMask        = 0x00200000,
  270.     hfsCIDoesDynamicLoadBit        = 20,                            /* set if dynamically loading code resource */
  271.     hfsCIDoesDynamicLoadMask    = 0x00100000,                    /*        supported */
  272.     hfsCIResourceLoadedBit        = 19,                            /* set if code resource already loaded */
  273.     hfsCIResourceLoadedMask        = 0x00080000,
  274.     hfsCIHasHLL2PProcBit        = 18,                            /* set if FFS' log2PhyProc and Extendfile proc */
  275.     hfsCIHasHLL2PProcMask        = 0x00040000,                    /* is written in a high level language. (i.e., uses Pascal calling convention) */
  276.     hfsCIWantsDTSupportBit        = 17,                            /* set if FFS wants the Mac OS's Desktop Manager code to handle */
  277.     hfsCIWantsDTSupportMask        = 0x00020000                    /* all Desktop Manager requests to its volumes. */
  278. };
  279.  
  280.  
  281. /*
  282.  *    Disk Initialization Component Interface constants
  283.  */
  284.  
  285. /*
  286.  * compInterfMask bits specific to Disk Initialization component
  287.  */
  288.  
  289. enum {
  290.     diCIHasExtFormatParamsBit    = 18,                            /* set if file system needs extended format */
  291.     diCIHasExtFormatParamsMask    = 0x00040000,                    /*        parameters */
  292.     diCIHasMultiVolTypesBit        = 17,                            /* set if file system supports more than one */
  293.     diCIHasMultiVolTypesMask    = 0x00020000,                    /*        volume type */
  294.     diCIDoesSparingBit            = 16,                            /* set if file system supports disk sparing */
  295.     diCIDoesSparingMask            = 0x00010000,
  296.     diCILiveBit                    = 0,                            /* set if file system is candidate for current */
  297.     diCILiveMask                = 0x00000001                    /*        formatting operation (set by PACK2) */
  298. };
  299.  
  300.  
  301. /*
  302.  * Disk Initialization Component Function selectors
  303.  */
  304.  
  305. enum {
  306.     diCILoad                    = 1,                            /* Make initialization code memory resident */
  307.     diCIUnload                    = 2,                            /* Make initialization code purgeable */
  308.     diCIEvaluateSizeChoices        = 3,                            /* Evaluate size choices */
  309.     diCIExtendedZero            = 4,                            /* Write an empty volume directory */
  310.     diCIValidateVolName            = 5,                            /* Validate volume name */
  311.     diCIGetVolTypeInfo            = 6,                            /* get volume type info */
  312.     diCIGetFormatString            = 7,                            /* get dialog format string */
  313.     diCIGetExtFormatParams        = 8,                            /* get extended format parameters */
  314.     diCIGetDefectList            = 9                                /* return the defect list for the indicated disk - reserved for future use */
  315. };
  316.  
  317.  
  318. /*
  319.  * Constants used in the DICIEvaluateSizeRec and FormatListRec
  320.  */
  321.  
  322. enum {
  323.     diCIFmtListMax                = 8,                            /* maximum number of format list entries in DICIEvaluateSizeRec.numSizeEntries */
  324.                                                                 /*    bits in FormatListRec.formatFlags: */
  325.     diCIFmtFlagsValidBit        = 7,                            /* set if sec, side, tracks valid */
  326.     diCIFmtFlagsValidMask        = 0x80,
  327.     diCIFmtFlagsCurrentBit        = 6,                            /* set if current disk has this fmt */
  328.     diCIFmtFlagsCurrentMask        = 0x40,                            /*    bits in FormatListRec.sizeListFlags: */
  329.     diCISizeListOKBit            = 15,                            /* set if this disk size usable */
  330.     diCISizeListOKMask            = 0x8000
  331. };
  332.  
  333.  
  334. /*
  335.  * DICIGetFormatStringRec.stringKind format strings
  336.  */
  337.  
  338. enum {
  339.     diCIAlternateFormatStr        = 1,                            /* get alternate format  string (Balloon Help) */
  340.     diCISizePresentationStr        = 2                                /* get size presentation string (for dialog) */
  341. };
  342.  
  343.  
  344. /*
  345.  * Error codes returned by Disk Sparing
  346.  */
  347.  
  348. enum {
  349.     diCIUserCancelErr            = 1,                            /* user cancelled the disk init */
  350.     diCICriticalSectorBadErr    = 20,                            /* critical sectors are bad (hopeless)    */
  351.     diCISparingFailedErr        = 21,                            /* disk cannot be spared */
  352.     diCITooManyBadSectorsErr    = 22,                            /* too many bad sectors */
  353.     diCIUnknownVolTypeErr        = 23,                            /* the volume type passed in diCIExtendedZero paramBlock is not supported */
  354.     diCIVolSizeMismatchErr        = 24,                            /* specified volume size doesn’t match with formatted disk size */
  355.     diCIUnknownDICallErr        = 25,                            /* bogus DI function call selector */
  356.     diCINoSparingErr            = 26,                            /* disk is bad but the target FS doesn't do disk sparing */
  357.     diCINoExtendInfoErr            = 27,                            /* missing file system specific extra parameter in diCIExtendedZero call */
  358.     diCINoMessageTextErr        = 28                            /* missing message text in DIReformat call */
  359. };
  360.  
  361.  
  362. /*
  363.  *    File System Manager constants
  364.  */
  365.  
  366. /*
  367.  * Miscellaneous constants used by FSM
  368.  */
  369.  
  370. enum {
  371.     fsdVersion1                    = 1,                            /* current version of FSD record */
  372.     fsmIgnoreFSID                = 0xFFFE,                        /* this FSID should be ignored by the driver */
  373.     fsmGenericFSID                = 0xFFFF                        /* unknown foreign file system ID */
  374. };
  375.  
  376.  
  377. /*
  378.  * compInterfMask bits common to all FSM components
  379.  */
  380.  
  381. enum {
  382.     fsmComponentEnableBit        = 31,                            /* set if FSM component interface is enabled */
  383.     fsmComponentEnableMask        = (long)0x80000000,
  384.     fsmComponentBusyBit            = 30,                            /* set if FSM component interface is busy */
  385.     fsmComponentBusyMask        = 0x40000000
  386. };
  387.  
  388.  
  389. /*
  390.  * Selectors for GetFSInfo
  391.  */
  392.  
  393. enum {
  394.     fsmGetFSInfoByIndex            = -1,                            /* get fs info by index */
  395.     fsmGetFSInfoByFSID            = 0,                            /* get fs info by FSID */
  396.     fsmGetFSInfoByRefNum        = 1                                /* get fs info by file/vol refnum */
  397. };
  398.  
  399.  
  400. /*
  401.  * InformFSM messages
  402.  */
  403.  
  404. enum {
  405.     fsmNopMessage                = 0,                            /* nop */
  406.     fsmDrvQElChangedMessage        = 1,                            /* DQE has changed */
  407.     fsmGetFSIconMessage            = 2                                /* Get FFS's disk icon */
  408. };
  409.  
  410.  
  411. /*
  412.  * Messages passed to the fileSystemCommProc
  413.  */
  414.  
  415. enum {
  416.     ffsNopMessage                = 0,                            /* nop, should always return noErr */
  417.     ffsGetIconMessage            = 1,                            /* return disk icon and mask */
  418.     ffsIDDiskMessage            = 2,                            /* identify the about-to-be-mounted volume */
  419.     ffsLoadMessage                = 3,                            /* load in the FFS */
  420.     ffsUnloadMessage            = 4,                            /* unload the FFS */
  421.     ffsIDVolMountMessage        = 5,                            /* identify a VolMountInfo record */
  422.     ffsInformMessage            = 6,                            /* FFS defined message */
  423.     ffsGetIconInfoMessage        = 7
  424. };
  425.  
  426.  
  427. /*
  428.  * Error codes from FSM functions
  429.  */
  430.  
  431. enum {
  432.     fsmFFSNotFoundErr            = -431,                            /* Foreign File system does not exist - new Pack2 could return this error too */
  433.     fsmBusyFFSErr                = -432,                            /* File system is busy, cannot be removed */
  434.     fsmBadFFSNameErr            = -433,                            /* Name length not 1 <= length <= 31 */
  435.     fsmBadFSDLenErr                = -434,                            /* FSD size incompatible with current FSM vers */
  436.     fsmDuplicateFSIDErr            = -435,                            /* FSID already exists on InstallFS */
  437.     fsmBadFSDVersionErr            = -436,                            /* FSM version incompatible with FSD */
  438.     fsmNoAlternateStackErr        = -437,                            /* no alternate stack for HFS CI */
  439.     fsmUnknownFSMMessageErr        = -438                            /* unknown message passed to FSM */
  440. };
  441.  
  442.  
  443. /*
  444.  *    HFS Utility routine records
  445.  */
  446.  
  447. /*
  448.  * record used by UTGetPathComponentName
  449.  */
  450.  
  451. struct ParsePathRec {
  452.     StringPtr                         namePtr;                    /* pathname to parse */
  453.     short                             startOffset;                /* where to start parsing */
  454.     short                             componentLength;            /* the length of the pathname component parsed */
  455.     SignedByte                         moreName;                    /* non-zero if there are more components after this one */
  456.     SignedByte                         foundDelimiter;                /* non-zero if parsing stopped because a colon (:) delimiter was found */
  457. };
  458. typedef struct ParsePathRec                ParsePathRec;
  459. typedef ParsePathRec *                    ParsePathRecPtr;
  460.  
  461. struct WDCBRec {
  462.     VCBPtr                             wdVCBPtr;                    /* Pointer to VCB of this working directory */
  463.     long                             wdDirID;                    /* Directory ID number of this working directory */
  464.     long                             wdCatHint;                    /* Hint for finding this working directory */
  465.     long                             wdProcID;                    /* Process that created this working directory */
  466. };
  467. typedef struct WDCBRec                    WDCBRec;
  468. typedef WDCBRec *                        WDCBRecPtr;
  469.  
  470. struct FCBRec {
  471.     unsigned long                     fcbFlNm;                    /* FCB file number. Non-zero marks FCB used */
  472.     SignedByte                         fcbFlags;                    /* FCB flags */
  473.     SignedByte                         fcbTypByt;                    /* File type byte */
  474.     unsigned short                     fcbSBlk;                    /* File start block (in alloc size blks) */
  475.     unsigned long                     fcbEOF;                        /* Logical length or EOF in bytes */
  476.     unsigned long                     fcbPLen;                    /* Physical file length in bytes */
  477.     unsigned long                     fcbCrPs;                    /* Current position within file */
  478.     VCBPtr                             fcbVPtr;                    /* Pointer to the corresponding VCB */
  479.     Ptr                             fcbBfAdr;                    /* File's buffer address */
  480.     unsigned short                     fcbFlPos;                    /* Directory block this file is in */
  481.                                                                 /* FCB Extensions for HFS */
  482.     unsigned long                     fcbClmpSize;                /* Number of bytes per clump */
  483.     Ptr                             fcbBTCBPtr;                    /* Pointer to B*-Tree control block for file */
  484.     unsigned long                     fcbExtRec[3];                /* First 3 file extents */
  485.     OSType                             fcbFType;                    /* File's 4 Finder Type bytes */
  486.     unsigned long                     fcbCatPos;                    /* Catalog hint for use on Close */
  487.     unsigned long                     fcbDirID;                    /* Parent Directory ID */
  488.     Str31                             fcbCName;                    /* CName of open file */
  489. };
  490. typedef struct FCBRec                    FCBRec;
  491. typedef FCBRec *                        FCBRecPtr;
  492. /*
  493.  *    HFS Component Interface records
  494.  */
  495. typedef CALLBACK_API( OSErr , Lg2PhysProcPtr )(void *fsdGlobalPtr, VCBPtr volCtrlBlockPtr, FCBRecPtr fileCtrlBlockPtr, short fileRefNum, unsigned long filePosition, unsigned long reqCount, unsigned long *volOffset, unsigned long *contiguousBytes);
  496. typedef STACK_UPP_TYPE(Lg2PhysProcPtr)                             Lg2PhysUPP;
  497. enum { uppLg2PhysProcInfo = 0x003FEFE0 };                         /* pascal 2_bytes Func(4_bytes, 4_bytes, 4_bytes, 2_bytes, 4_bytes, 4_bytes, 4_bytes, 4_bytes) */
  498. #define NewLg2PhysProc(userRoutine)                             (Lg2PhysUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppLg2PhysProcInfo, GetCurrentArchitecture())
  499. #define CallLg2PhysProc(userRoutine, fsdGlobalPtr, volCtrlBlockPtr, fileCtrlBlockPtr, fileRefNum, filePosition, reqCount, volOffset, contiguousBytes)  CALL_EIGHT_PARAMETER_UPP((userRoutine), uppLg2PhysProcInfo, (fsdGlobalPtr), (volCtrlBlockPtr), (fileCtrlBlockPtr), (fileRefNum), (filePosition), (reqCount), (volOffset), (contiguousBytes))
  500. typedef CALLBACK_API( OSErr , HFSCIProcPtr )(VCBPtr theVCB, short selectCode, void *paramBlock, void *fsdGlobalPtr, short fsid);
  501. typedef STACK_UPP_TYPE(HFSCIProcPtr)                             HFSCIUPP;
  502. enum { uppHFSCIProcInfo = 0x0000BEE0 };                         /* pascal 2_bytes Func(4_bytes, 2_bytes, 4_bytes, 4_bytes, 2_bytes) */
  503. #define NewHFSCIProc(userRoutine)                                 (HFSCIUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppHFSCIProcInfo, GetCurrentArchitecture())
  504. #define CallHFSCIProc(userRoutine, theVCB, selectCode, paramBlock, fsdGlobalPtr, fsid)  CALL_FIVE_PARAMETER_UPP((userRoutine), uppHFSCIProcInfo, (theVCB), (selectCode), (paramBlock), (fsdGlobalPtr), (fsid))
  505.  
  506. struct HFSCIRec {
  507.     long                             compInterfMask;                /* component flags */
  508.     HFSCIUPP                         compInterfProc;                /* pointer to file system call processing code */
  509.     Lg2PhysUPP                         log2PhyProc;                /* pointer to Lg2PhysProc() code */
  510.     Ptr                             stackTop;                    /* file system stack top */
  511.     long                             stackSize;                    /* file system stack size */
  512.     Ptr                             stackPtr;                    /* current file system stack pointer */
  513.     long                             reserved3;                    /* --reserved, must be zero-- */
  514.     long                             idSector;                    /* Sector you need to ID a local volume. For networked volumes, this must be -1 */
  515.     long                             reserved2;                    /* --reserved, must be zero-- */
  516.     long                             reserved1;                    /* --reserved, must be zero-- */
  517. };
  518. typedef struct HFSCIRec                    HFSCIRec;
  519. typedef HFSCIRec *                        HFSCIRecPtr;
  520. /*
  521.  *    Disk Initialization Component Interface records
  522.  */
  523. typedef CALLBACK_API( OSErr , DICIProcPtr )(short whatFunction, void *paramBlock, void *fsdGlobalPtr);
  524. typedef STACK_UPP_TYPE(DICIProcPtr)                             DICIUPP;
  525. enum { uppDICIProcInfo = 0x00000FA0 };                             /* pascal 2_bytes Func(2_bytes, 4_bytes, 4_bytes) */
  526. #define NewDICIProc(userRoutine)                                 (DICIUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppDICIProcInfo, GetCurrentArchitecture())
  527. #define CallDICIProc(userRoutine, whatFunction, paramBlock, fsdGlobalPtr)  CALL_THREE_PARAMETER_UPP((userRoutine), uppDICIProcInfo, (whatFunction), (paramBlock), (fsdGlobalPtr))
  528.  
  529. struct DICIRec {
  530.     long                             compInterfMask;                /* component flags */
  531.     DICIUPP                         compInterfProc;                /* pointer to call processing code */
  532.     short                             maxVolNameLength;            /* maximum length of your volume name */
  533.     unsigned short                     blockSize;                    /* your file system's block size */
  534.     long                             reserved3;                    /* --reserved, must be zero-- */
  535.     long                             reserved2;                    /* --reserved, must be zero-- */
  536.     long                             reserved1;                    /* --reserved, must be zero-- */
  537. };
  538. typedef struct DICIRec                    DICIRec;
  539. typedef DICIRec *                        DICIRecPtr;
  540. /*
  541.  * FormatListRec as returned by the .Sony disk driver's
  542.  * Return Format List status call (csCode = 6).
  543.  * If the status call to get this list for a drive is not
  544.  * implemented by the driver, then a list with one entry
  545.  * is contructed from the drive queue element for the drive.
  546.  */
  547.  
  548. struct FormatListRec {
  549.     unsigned long                     volSize;                    /* disk capacity in SECTORs */
  550.     SignedByte                         formatFlags;                /* flags */
  551.     SignedByte                         sectorsPerTrack;            /* sectors per track side */
  552.     unsigned short                     tracks;                        /* number of tracks */
  553. };
  554. typedef struct FormatListRec            FormatListRec;
  555. typedef FormatListRec *                    FormatListRecPtr;
  556. /*
  557.  * SizeListRec built from FormatListRecs as described above.
  558.  */
  559.  
  560. struct SizeListRec {
  561.     short                             sizeListFlags;                /* flags as set by external file system */
  562.     FormatListRec                     sizeEntry;                    /* disk driver format list record */
  563. };
  564. typedef struct SizeListRec                SizeListRec;
  565. typedef SizeListRec *                    SizeListRecPtr;
  566. /*
  567.  * paramBlock for the diCIEvaluateSize call
  568.  */
  569.  
  570. struct DICIEvaluateSizeRec {
  571.     short                             defaultSizeIndex;            /* default size for this FS */
  572.     short                             numSizeEntries;                /* number of size entries */
  573.     short                             driveNumber;                /* drive number */
  574.     SizeListRecPtr                     sizeListPtr;                /* ptr to size entry table */
  575.     unsigned short                     sectorSize;                    /* bytes per sector */
  576. };
  577. typedef struct DICIEvaluateSizeRec        DICIEvaluateSizeRec;
  578. typedef DICIEvaluateSizeRec *            DICIEvaluateSizeRecPtr;
  579. /*
  580.  * paramBlock for the diCIExtendedZero call
  581.  */
  582.  
  583. struct DICIExtendedZeroRec {
  584.     short                             driveNumber;                /* drive number */
  585.     StringPtr                         volNamePtr;                    /* ptr to volume name string */
  586.     short                             fsid;                        /* file system ID */
  587.     short                             volTypeSelector;            /* volume type selector, if supports more than 1 type */
  588.     unsigned short                     numDefectBlocks;            /* number of bad logical blocks */
  589.     unsigned short                     defectListSize;                /* size of the defect list buffer in bytes */
  590.     Ptr                             defectListPtr;                /* pointer to defect list buffer */
  591.     unsigned long                     volSize;                    /* size of volume in SECTORs */
  592.     unsigned short                     sectorSize;                    /* bytes per sector */
  593.     Ptr                             extendedInfoPtr;            /* ptr to extended info */
  594. };
  595. typedef struct DICIExtendedZeroRec        DICIExtendedZeroRec;
  596. typedef DICIExtendedZeroRec *            DICIExtendedZeroRecPtr;
  597. /*
  598.  * paramBlock for the diCIValidateVolName call
  599.  */
  600.  
  601. struct DICIValidateVolNameRec {
  602.     char                             theChar;                    /* the character to validate */
  603.     Boolean                         hasMessageBuffer;            /* false if no message */
  604.     short                             charOffset;                    /* position of the current character (first char = 1) */
  605.     StringPtr                         messageBufferPtr;            /* pointer to message buffer or nil */
  606.     short                             charByteType;                /* theChar's byte type (smSingleByte, smFirstByte, or smLastByte) */
  607. };
  608. typedef struct DICIValidateVolNameRec    DICIValidateVolNameRec;
  609. typedef DICIValidateVolNameRec *        DICIValidateVolNameRecPtr;
  610. /*
  611.  * paramBlock for the diCIGetVolTypeInfo call
  612.  */
  613.  
  614. struct DICIGetVolTypeInfoRec {
  615.     unsigned long                     volSize;                    /* size of volume in SECTORs */
  616.     unsigned short                     sectorSize;                    /* bytes per sector */
  617.     short                             numVolTypes;                /* number of volume types supported */
  618.     Str31                             volTypesBuffer[4];            /* 4 string buffers */
  619. };
  620. typedef struct DICIGetVolTypeInfoRec    DICIGetVolTypeInfoRec;
  621. typedef DICIGetVolTypeInfoRec *            DICIGetVolTypeInfoRecPtr;
  622. /*
  623.  * paramBlock for the diCIGetFormatString call
  624.  */
  625.  
  626. struct DICIGetFormatStringRec {
  627.     unsigned long                     volSize;                    /* volume size in SECTORs */
  628.     unsigned short                     sectorSize;                    /* sector size */
  629.     short                             volTypeSelector;            /* volume type selector */
  630.     short                             stringKind;                    /* sub-function = type of string */
  631.     Str255                             stringBuffer;                /* string buffer */
  632. };
  633. typedef struct DICIGetFormatStringRec    DICIGetFormatStringRec;
  634. typedef DICIGetFormatStringRec *        DICIGetFormatStringRecPtr;
  635. /*
  636.  * paramBlock for the diCIGetExtendedFormatParams call
  637.  */
  638.  
  639. struct DICIGetExtendedFormatRec {
  640.     short                             driveNumber;                /* drive number */
  641.     short                             volTypeSelector;            /* volume type selector or 0 */
  642.     unsigned long                     volSize;                    /* size of volume in SECTORs */
  643.     unsigned short                     sectorSize;                    /* bytes per sector */
  644.     FSSpecPtr                         fileSystemSpecPtr;            /* pointer to the foreign file system's FSSpec */
  645.     Ptr                             extendedInfoPtr;            /* pointer to extended parameter structure */
  646. };
  647. typedef struct DICIGetExtendedFormatRec    DICIGetExtendedFormatRec;
  648. typedef DICIGetExtendedFormatRec *        DICIGetExtendedFormatRecPtr;
  649. /*
  650.  *    File System Manager records
  651.  */
  652.  
  653. typedef CALLBACK_API( OSErr , FSDCommProcPtr )(short message, void *paramBlock, void *globalsPtr);
  654. typedef STACK_UPP_TYPE(FSDCommProcPtr)                             FSDCommUPP;
  655. enum { uppFSDCommProcInfo = 0x00000FA0 };                         /* pascal 2_bytes Func(2_bytes, 4_bytes, 4_bytes) */
  656. #define NewFSDCommProc(userRoutine)                             (FSDCommUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppFSDCommProcInfo, GetCurrentArchitecture())
  657. #define CallFSDCommProc(userRoutine, message, paramBlock, globalsPtr)  CALL_THREE_PARAMETER_UPP((userRoutine), uppFSDCommProcInfo, (message), (paramBlock), (globalsPtr))
  658. typedef struct FSDRec                     FSDRec;
  659.  
  660. struct FSDRec {
  661.     struct FSDRec *                    fsdLink;                    /* ptr to next */
  662.     short                             fsdLength;                    /* length of this FSD in BYTES */
  663.     short                             fsdVersion;                    /* version number */
  664.     short                             fileSystemFSID;                /* file system id */
  665.     Str31                             fileSystemName;                /* file system name */
  666.     FSSpec                             fileSystemSpec;                /* foreign file system's FSSpec */
  667.     Ptr                             fileSystemGlobalsPtr;        /* ptr to file system globals */
  668.     FSDCommUPP                         fileSystemCommProc;            /* communication proc with the FFS */
  669.     long                             reserved3;                    /* --reserved, must be zero-- */
  670.     long                             reserved2;                    /* --reserved, must be zero-- */
  671.     long                             reserved1;                    /* --reserved, must be zero-- */
  672.     HFSCIRec                         fsdHFSCI;                    /* HFS component interface    */
  673.     DICIRec                         fsdDICI;                    /* Disk Initialization component interface */
  674. };
  675.  
  676.  
  677. typedef FSDRec *                        FSDRecPtr;
  678.  
  679. struct FSMGetIconInfoRec {
  680.     long                             theIcon[32];                /* The ICN# structure */
  681.     long                             theMask[32];                /* The mask for the icon above */
  682.     Str255                             whereStr;
  683. };
  684. typedef struct FSMGetIconInfoRec        FSMGetIconInfoRec;
  685. typedef FSMGetIconInfoRec *                FSMGetIconInfoRecPtr;
  686. /*
  687.  * paramBlock for ffsGetIconMessage and fsmGetFSIconMessage
  688.  */
  689.  
  690. struct FSMGetIconRec {
  691.     short                             refNum;                        /* target drive num or volume refnum */
  692.     FSMGetIconInfoRecPtr             iconBufferPtr;                /* pointer to icon buffer */
  693.     long                             requestSize;                /* requested size of the icon buffer */
  694.     long                             actualSize;                    /* actual size of the icon data returned */
  695.     SInt8                             iconType;                    /* kind of icon */
  696.     Boolean                         isEjectable;                /* true if the device is ejectable */
  697.     DrvQElPtr                         driveQElemPtr;                /* pointer to DQE */
  698.     FSSpecPtr                         fileSystemSpecPtr;            /* pointer to foreign file system's FSSpec */
  699.     long                             reserved1;                    /* --reserved, must be zero-- */
  700. };
  701. typedef struct FSMGetIconRec            FSMGetIconRec;
  702. typedef FSMGetIconRec *                    FSMGetIconRecPtr;
  703. /*
  704.  *    HFS Utility routine prototypes
  705.  */
  706. EXTERN_API( OSErr )
  707. UTAllocateFCB                    (short *                fileRefNum,
  708.                                  FCBRecPtr *            fileCtrlBlockPtr)                    TWOWORDINLINE(0x7000, 0xA824);
  709.  
  710. EXTERN_API( OSErr )
  711. UTReleaseFCB                    (short                     fileRefNum)                            TWOWORDINLINE(0x7001, 0xA824);
  712.  
  713. EXTERN_API( OSErr )
  714. UTLocateFCB                        (VCBPtr                 volCtrlBlockPtr,
  715.                                  unsigned long             fileNum,
  716.                                  StringPtr                 namePtr,
  717.                                  short *                fileRefNum,
  718.                                  FCBRecPtr *            fileCtrlBlockPtr)                    TWOWORDINLINE(0x7002, 0xA824);
  719.  
  720. EXTERN_API( OSErr )
  721. UTLocateNextFCB                    (VCBPtr                 volCtrlBlockPtr,
  722.                                  unsigned long             fileNum,
  723.                                  StringPtr                 namePtr,
  724.                                  short *                fileRefNum,
  725.                                  FCBRecPtr *            fileCtrlBlockPtr)                    TWOWORDINLINE(0x7003, 0xA824);
  726.  
  727. EXTERN_API( OSErr )
  728. UTIndexFCB                        (VCBPtr                 volCtrlBlockPtr,
  729.                                  short *                fileRefNum,
  730.                                  FCBRecPtr *            fileCtrlBlockPtr)                    TWOWORDINLINE(0x7004, 0xA824);
  731.  
  732. EXTERN_API( OSErr )
  733. UTResolveFCB                    (short                     fileRefNum,
  734.                                  FCBRecPtr *            fileCtrlBlockPtr)                    TWOWORDINLINE(0x7005, 0xA824);
  735.  
  736. EXTERN_API( OSErr )
  737. UTAllocateVCB                    (unsigned short *        sysVCBLength,
  738.                                  VCBPtr *                volCtrlBlockPtr,
  739.                                  unsigned short         addSize)                            TWOWORDINLINE(0x7006, 0xA824);
  740.  
  741. EXTERN_API( OSErr )
  742. UTAddNewVCB                        (short                     driveNum,
  743.                                  short *                vRefNum,
  744.                                  VCBPtr                 volCtrlBlockPtr)                    TWOWORDINLINE(0x7007, 0xA824);
  745.  
  746. EXTERN_API( OSErr )
  747. UTDisposeVCB                    (VCBPtr                 volCtrlBlockPtr)                    TWOWORDINLINE(0x7008, 0xA824);
  748.  
  749. EXTERN_API( OSErr )
  750. UTLocateVCBByRefNum                (short                     refNum,
  751.                                  short *                vRefNum,
  752.                                  VCBPtr *                volCtrlBlockPtr)                    TWOWORDINLINE(0x7009, 0xA824);
  753.  
  754. EXTERN_API( OSErr )
  755. UTLocateVCBByName                (StringPtr                 namePtr,
  756.                                  short *                moreMatches,
  757.                                  short *                vRefNum,
  758.                                  VCBPtr *                volCtrlBlockPtr)                    TWOWORDINLINE(0x700A, 0xA824);
  759.  
  760. EXTERN_API( OSErr )
  761. UTLocateNextVCB                    (StringPtr                 namePtr,
  762.                                  short *                moreMatches,
  763.                                  short *                vRefNum,
  764.                                  VCBPtr *                volCtrlBlockPtr)                    TWOWORDINLINE(0x700B, 0xA824);
  765.  
  766. EXTERN_API( OSErr )
  767. UTAllocateWDCB                    (WDPBPtr                 paramBlock)                            TWOWORDINLINE(0x700C, 0xA824);
  768.  
  769. EXTERN_API( OSErr )
  770. UTReleaseWDCB                    (short                     wdRefNum)                            TWOWORDINLINE(0x700D, 0xA824);
  771.  
  772. EXTERN_API( OSErr )
  773. UTResolveWDCB                    (long                     procID,
  774.                                  short                     wdIndex,
  775.                                  short                     wdRefNum,
  776.                                  WDCBRecPtr *            wdCtrlBlockPtr)                        TWOWORDINLINE(0x700E, 0xA824);
  777.  
  778. EXTERN_API( OSErr )
  779. UTFindDrive                        (short                     driveNum,
  780.                                  DrvQElPtr *            driveQElementPtr)                    TWOWORDINLINE(0x700F, 0xA824);
  781.  
  782. EXTERN_API( OSErr )
  783. UTAdjustEOF                        (short                     fileRefNum)                            TWOWORDINLINE(0x7010, 0xA824);
  784.  
  785. EXTERN_API( OSErr )
  786. UTSetDefaultVol                    (long                     nodeHint,
  787.                                  unsigned long             dirID,
  788.                                  short                     refNum)                                TWOWORDINLINE(0x7011, 0xA824);
  789.  
  790. EXTERN_API( OSErr )
  791. UTGetDefaultVol                    (WDPBPtr                 paramBlock)                            TWOWORDINLINE(0x7012, 0xA824);
  792.  
  793. EXTERN_API( OSErr )
  794. UTEjectVol                        (VCBPtr                 volCtrlBlockPtr)                    TWOWORDINLINE(0x702B, 0xA824);
  795.  
  796. EXTERN_API( OSErr )
  797. UTCheckWDRefNum                    (short                     wdRefNum)                            TWOWORDINLINE(0x7013, 0xA824);
  798.  
  799. EXTERN_API( OSErr )
  800. UTCheckFileRefNum                (short                     fileRefNum)                            TWOWORDINLINE(0x7014, 0xA824);
  801.  
  802. EXTERN_API( OSErr )
  803. UTCheckVolRefNum                (short                     vRefNum)                            TWOWORDINLINE(0x7015, 0xA824);
  804.  
  805. EXTERN_API( OSErr )
  806. UTCheckPermission                (VCBPtr                 volCtrlBlockPtr,
  807.                                  short *                modByte,
  808.                                  unsigned long             fileNum,
  809.                                  ParmBlkPtr             paramBlock)                            TWOWORDINLINE(0x7016, 0xA824);
  810.  
  811. EXTERN_API( OSErr )
  812. UTCheckVolOffline                (short                     vRefNum)                            TWOWORDINLINE(0x7017, 0xA824);
  813.  
  814. EXTERN_API( OSErr )
  815. UTCheckVolModifiable            (short                     vRefNum)                            TWOWORDINLINE(0x7018, 0xA824);
  816.  
  817. EXTERN_API( OSErr )
  818. UTCheckFileModifiable            (short                     fileRefNum)                            TWOWORDINLINE(0x7019, 0xA824);
  819.  
  820. EXTERN_API( OSErr )
  821. UTCheckDirBusy                    (VCBPtr                 volCtrlBlockPtr,
  822.                                  unsigned long             dirID)                                TWOWORDINLINE(0x701A, 0xA824);
  823.  
  824. EXTERN_API( OSErr )
  825. UTParsePathname                    (short *                volNamelength,
  826.                                  StringPtr                 namePtr)                            TWOWORDINLINE(0x701B, 0xA824);
  827.  
  828. EXTERN_API( OSErr )
  829. UTGetPathComponentName            (ParsePathRecPtr         parseRec)                            TWOWORDINLINE(0x701C, 0xA824);
  830.  
  831. EXTERN_API( OSErr )
  832. UTDetermineVol                    (ParmBlkPtr             paramBlock,
  833.                                  short *                status,
  834.                                  short *                moreMatches,
  835.                                  short *                vRefNum,
  836.                                  VCBPtr *                volCtrlBlockPtr)                    TWOWORDINLINE(0x701D, 0xA824);
  837.  
  838. EXTERN_API( OSErr )
  839. UTGetBlock                        (short                     refNum,
  840.                                  void *                    log2PhyProc,
  841.                                  unsigned long             blockNum,
  842.                                  short                     gbOption,
  843.                                  Ptr *                    buffer)                                TWOWORDINLINE(0x701F, 0xA824);
  844.  
  845. EXTERN_API( OSErr )
  846. UTReleaseBlock                    (Ptr                     buffer,
  847.                                  short                     rbOption)                            TWOWORDINLINE(0x7020, 0xA824);
  848.  
  849. EXTERN_API( OSErr )
  850. UTFlushCache                    (short                     refNum,
  851.                                  short                     fcOption)                            TWOWORDINLINE(0x7021, 0xA824);
  852.  
  853. EXTERN_API( OSErr )
  854. UTMarkDirty                        (Ptr                     buffer)                                TWOWORDINLINE(0x7023, 0xA824);
  855.  
  856. EXTERN_API( OSErr )
  857. UTTrashVolBlocks                (VCBPtr                 volCtrlBlockPtr)                    TWOWORDINLINE(0x7024, 0xA824);
  858.  
  859. EXTERN_API( OSErr )
  860. UTTrashFileBlocks                (VCBPtr                 volCtrlBlockPtr,
  861.                                  unsigned long             fileNum)                            TWOWORDINLINE(0x7025, 0xA824);
  862.  
  863. EXTERN_API( OSErr )
  864. UTTrashBlocks                    (unsigned long             beginPosition,
  865.                                  unsigned long             byteCount,
  866.                                  VCBPtr                 volCtrlBlockPtr,
  867.                                  short                     fileRefNum,
  868.                                  short                     tbOption)                            TWOWORDINLINE(0x7026, 0xA824);
  869.  
  870. EXTERN_API( OSErr )
  871. UTCacheReadIP                    (void *                    log2PhyProc,
  872.                                  unsigned long             filePosition,
  873.                                  Ptr                     ioBuffer,
  874.                                  short                     fileRefNum,
  875.                                  unsigned long             reqCount,
  876.                                  unsigned long *        actCount,
  877.                                  short                     cacheOption)                        TWOWORDINLINE(0x7027, 0xA824);
  878.  
  879. EXTERN_API( OSErr )
  880. UTCacheWriteIP                    (void *                    log2PhyProc,
  881.                                  unsigned long             filePosition,
  882.                                  Ptr                     ioBuffer,
  883.                                  short                     fileRefNum,
  884.                                  unsigned long             reqCount,
  885.                                  unsigned long *        actCount,
  886.                                  short                     cacheOption)                        TWOWORDINLINE(0x7028, 0xA824);
  887.  
  888. EXTERN_API( OSErr )
  889. UTBlockInFQHashP                (short                     vRefNum,
  890.                                  unsigned long             diskBlock)                            TWOWORDINLINE(0x702C, 0xA824);
  891.  
  892. EXTERN_API( OSErr )
  893. UTVolCacheReadIP                (VCBPtr                 volCtrlBlockPtr,
  894.                                  unsigned long             blockPosition,
  895.                                  Ptr                     ioBuffer,
  896.                                  unsigned long             reqCount,
  897.                                  unsigned long *        actCount,
  898.                                  short                     cacheOption)                        TWOWORDINLINE(0x7034, 0xA824);
  899.  
  900. EXTERN_API( OSErr )
  901. UTVolCacheWriteIP                (VCBPtr                 volCtrlBlockPtr,
  902.                                  unsigned long             blockPosition,
  903.                                  Ptr                     ioBuffer,
  904.                                  unsigned long             reqCount,
  905.                                  unsigned long *        actCount,
  906.                                  short                     cacheOption)                        TWOWORDINLINE(0x7035, 0xA824);
  907.  
  908.  
  909.  
  910. /*
  911.  *    File System Manager call prototypes
  912.  */
  913.                                                                                             #if TARGET_OS_MAC && TARGET_CPU_68K && !TARGET_RT_MAC_CFM
  914.                                                                                             #pragma parameter __D0 InstallFS(__A0)
  915.                                                                                             #endif
  916. EXTERN_API( OSErr )
  917. InstallFS                        (FSDRecPtr                 fsdPtr)                                TWOWORDINLINE(0x7000, 0xA0AC);
  918.  
  919.                                                                                             #if TARGET_OS_MAC && TARGET_CPU_68K && !TARGET_RT_MAC_CFM
  920.                                                                                             #pragma parameter __D0 RemoveFS(__A0)
  921.                                                                                             #endif
  922. EXTERN_API( OSErr )
  923. RemoveFS                        (short                     fsid)                                TWOWORDINLINE(0x7001, 0xA0AC);
  924.  
  925. EXTERN_API( OSErr )
  926. SetFSInfo                        (short                     fsid,
  927.                                  short                     bufSize,
  928.                                  FSDRecPtr                 fsdPtr);
  929.  
  930. EXTERN_API( OSErr )
  931. GetFSInfo                        (short                     selector,
  932.                                  short                     key,
  933.                                  short *                bufSize,
  934.                                  FSDRecPtr                 fsdPtr);
  935.  
  936. EXTERN_API( OSErr )
  937. InformFSM                        (short                     theMessage,
  938.                                  void *                    paramBlock);
  939.  
  940. EXTERN_API( OSErr )
  941. InformFFS                        (short                     fsid,
  942.                                  void *                    paramBlock);
  943.  
  944.  
  945.  
  946.  
  947. #if PRAGMA_STRUCT_ALIGN
  948.     #pragma options align=reset
  949. #elif PRAGMA_STRUCT_PACKPUSH
  950.     #pragma pack(pop)
  951. #elif PRAGMA_STRUCT_PACK
  952.     #pragma pack()
  953. #endif
  954.  
  955. #ifdef PRAGMA_IMPORT_OFF
  956. #pragma import off
  957. #elif PRAGMA_IMPORT
  958. #pragma import reset
  959. #endif
  960.  
  961. #ifdef __cplusplus
  962. }
  963. #endif
  964.  
  965. #endif /* __FSM__ */
  966.  
  967.